package com.silverbox.waimai.common;

public class SweepOrderUtils {

	/**
	 * 拼接订单序号，不足4位补足
	 * 
	 * @param orderSeq
	 * @return
	 */
	public static String getOrderSeq(String orderSeqStr) {
		if (null == orderSeqStr) {
			return "0000";
		} else {
			if (orderSeqStr.length() == 1) {
				return "000" + orderSeqStr;
			} else if (orderSeqStr.length() == 2) {
				return "00" + orderSeqStr;
			} else if (orderSeqStr.length() == 1) {
				return "0" + orderSeqStr;
			} else {
				return orderSeqStr;
			}
		}
	}
}
